/**
 * Dwr-backed State provider.  
 Usage:  
 new Ext.state.LoggingStateProvider(MyDwrProxy.mySetFunction,MyDwrProxy.myClearFunction);


Each function should implement the signiture: 
myFunction(String userId, String settingName, String settingValue) 

 
**/


Ext.state.LoggingStateProvider = function(options){
    Ext.state.LoggingStateProvider.superclass.constructor.call(this,options);
 };

Ext.extend(Ext.state.LoggingStateProvider, Ext.state.CookieProvider, {
	// private
		set : function(name, value) {
			console.log('Set:'+name+' - '+value);
			Ext.state.LoggingStateProvider.superclass.set.call(this, name, value);
		},

		// private
		clear : function(name) {
			console.log('Clear:'+name);
			Ext.state.LoggingStateProvider.superclass.clear.call(this, name);
		},

		// private
		get : function(name, defaultValue) {
		 console.log('Get:'+name +'('+defaultValue+')');
			Ext.state.LoggingStateProvider.superclass.get.call(this, name,defaultValue);
		},
		
	 readCookies : function(){
		console.log('readCookies()');
        return  Ext.state.LoggingStateProvider.superclass.readCookies.call(this);
    }


});
		
Ext.override(Ext.Component,{
   //stateful:false
}); //Thanks: http://extjs.com/forum/showthread.php?t=15675

